package han;

import java.util.Scanner;

public class J09Circle {

	public static void main(String[] args) {
		double Radius[] = new double[2];
		final double PI[] =new double [2];
		double getArea[] = new double[2];
		double getPerimeter[] = new double[2];
		input(Radius, PI);
		getArea(getArea, Radius, PI);
		getPerimeter(getPerimeter, Radius, PI);
		
	
		System.out.println("넓이 = " + getArea[1]);
		System.out.println("둘레 = " + getPerimeter[1]);
		
}
	public static void input(double[] Radius,double[] PI){
		Scanner sc= null;;
		PI[1]=3.14;
		//클래스변수를 초기화할때는 null사용
		 sc = new Scanner(System.in);
		 System.out.println("반지름을 입력해주세요");
		 Radius[1] = sc.nextDouble();
		 sc.close();
	}
	public static void getArea(double[] getArea,double[] Radius,double[] PI){
		getArea[1] = Radius[1] * Radius[1] * PI[1];
	}
	public static void getPerimeter(double[] getPerimeter, double[] Radius,double[] PI){
		getPerimeter[1] = Radius[1] * 2 * PI[1];
	}
}
